package com.zbxx.practice.designpattern.celue;

/**
 * @author
 * @date 2019/05/31
 */
public class Main {

    public static void main(String[] args) {
        Car car = new Audi();
        car.setColor(new Red());
        car.run();
        car.show();
        /**
         * 策略模式 即多用组合
         */
        Car car2 = new Benz();
        car2.setColor(new Green());
        car2.run();
        car2.show();
    }

}
